package com.news.user.controller.v1;

import com.news.model.common.dtos.ResponseResult;
import com.news.model.user.dtos.ApUserFollowDto;
import com.news.user.service.ApUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/v1/user")
public class ApUserController {

    @Autowired
    private ApUserService apUserService;

    /**
     * 关注与取消关注
     * @param apUserFollowDto
     * @return
     */
    @PostMapping("/user_follow")
    public ResponseResult userFollow(@RequestBody ApUserFollowDto apUserFollowDto){
        return apUserService.userFollow(apUserFollowDto);
    }

}
